package com.bootcamp.java;

/**
 * @program: ArrayCode
 * @description:
 * @author: Keyu Li
 * @create: 2021-08-26 21:55
 **/

public class ReferenceTrans {
    public static void main(String[] args) {
        int a = 10;
        int b = 20;
        int[] ab = {a, b};
        method(ab);
        a = ab[0];
        b = ab[1];
        System.out.println("a = " + a);
        System.out.println("b = " + b);
    }

    public static void method(int[] ab) {
        ab[0] *= 2;
        ab[1] *= 2;
    }
}
